import $http from "./requst";
// 是否为店铺
export const is_shop = data =>
  $http({ url: "/shopapi/Index/is_shop", method: "post", data });
// 会员充值记录
export const user_member_record = data =>
  $http({ url: "/shopapi/Index/user_member_record", method: "post", data });
// 会员列表
export const member_user = data =>
  $http({ url: "/shopapi/Index/member_user", method: "post", data });
// 消费排行
export const consumption = data =>
  $http({ url: "/shopapi/Index/consumption", method: "post", data });

// 首页数据
export const shopapi = data => $http({ url: "/shopapi", method: "post", data });
// 展示店铺
export const show = data =>
  $http({
    url: "/shopapi/Shop/show",
    method: "post",
    data
  });
// 店铺编辑
export const save = data =>
  $http({
    url: "/shopapi/Shop/save",
    method: "post",
    data
  });
// 删除优惠券
export const coupon_del = data =>
  $http({
    url: "/shopapi/Index/coupon_del",
    method: "post",
    data
  });
// 优惠券列表
export const coupon = data =>
  $http({ url: "/shopapi/Index/coupon", method: "post", data });

// 优惠券新增
export const coupon_add = data =>
  $http({ url: "/shopapi/Index/coupon_add", method: "post", data });
// 修改会员设置
export const memberSet = data =>
  $http({
    url: "/shopapi/Index/memberSet",
    method: "post",
    data
  });
// 展示会员设置
export const memberShow = data =>
  $http({
    url: "/shopapi/Index/memberShow",
    method: "post",
    data
  });
// 商品删除
export const delGoods = data =>
  $http({
    url: "/shopapi/Goods/del",
    method: "post",
    data
  });
// 显示商品回显
export const showGoods = data =>
  $http({
    url: "/shopapi/Goods/show",
    method: "post",
    data
  });
// 商品列表
export const Goods = data =>
  $http({
    url: "/shopapi/Goods",
    method: "post",
    data
  });
// 新增编辑商品
export const saveGoods = data =>
  $http({
    url: "/shopapi/Goods/save",
    method: "post",
    data
  });
// 订单列表
export const orderList = data =>
  $http({
    url: "/shopapi/Order",
    method: "post",
    data
  });
// 订单详情
export const orderComplete = data =>
  $http({
    url: "/shopapi/Order/orderComplete",
    method: "post",
    data
  });
// 余额充值设置列表
export const balanceRecharge = data =>
  $http({
    url: "/shopapi/Shop/balanceRecharge",
    method: "post",
    data
  });
// 余额充值设置删除
export const balanceRechargeDel = data =>
  $http({
    url: "/shopapi/Shop/balanceRechargeDel",
    method: "post",
    data
  });
// 余额充值设置新增
export const balanceRechargeAdd = data =>
  $http({
    url: "/shopapi/Shop/balanceRechargeAdd",
    method: "post",
    data
  });
// 完成订单操作
export const orderDetails = data =>
  $http({
    url: "/shopapi/Order/orderDetails",
    method: "post",
    data
  });
